package vashion.azeroth.context.pojo;

import java.math.BigDecimal;
import java.util.Date;

import vashion.azeroth.common.math.BigDecimalUtil;
import vashion.azeroth.contant.AzerothConstants;
import vashion.azeroth.core.pojo.BaseObject;

import com.alibaba.fastjson.annotation.JSONField;

public class PersonalFavoritesItemContext extends BaseObject {

	private static final long serialVersionUID = -6122695319450793177L;

	/**
	 * 
	 * 主健ID
	 * */
	private Long favoritesId;

	/**
	 * 会员ID
	 * 
	 * */
	private Long memberId;

	/**
	 * 会员名称
	 * */
	private String memberName;

	/**
	 * 
	 * 发布者ID
	 * 
	 * */
	private Long publishMemberId;

	/**
	 * 
	 * 发布者名称
	 * 
	 * */
	private String publishMemberName;

	/**
	 * 
	 * 商品编码 或 文章编码
	 * 
	 * 关联 type
	 * */
	@JSONField(name = "goodId")
	private String targetCode;
	
	/**
	 * 
	 * 商品状态
	 * */
	private Integer itemStatus;

	/**
	 * 
	 * 关注类型
	 * 
	 * @see AzerothConstants.PersonalFavtoriesType
	 * 
	 * */
	private Integer type;

	/**
	 * 关注状态
	 * 
	 * @see AzerothConstants.PersonalFavtoriesStatus
	 * */
	private Integer status;
	
	/**
	 * 商品编码
	 */
	private String itemCode;
	
	/**
	 * 同编码商品总库存
	 * */
	private Integer stock;

	/**
	 * 创建时间
	 * */
	private Date timeAdd;

	/**
	 * 修改时间
	 * */
	private Date timeEdit;

	/**
	 * 修改时间
	 * */
	private String brandTitle;
	
	/**
	 * 贴子ID
	 * 
	 * 用于后面佣金的支持，可以为空
	 * 
	 * */
	private Integer publishFileId;

	/**
	 * 备注
	 * */
	private String remark;

	/**
	 * 商品名称
	 * 
	 * */
	private String itemName;

	/**
	 * 商品图片
	 * 
	 * */
	private String itemPic;

	/**
	 * 商品价格
	 * 
	 * */
	private String itemPrice;
	
	/**
	 * 商品价格币种编码
	 * 
	 * */
	private String itemPriceCurno;

	/**
     * 用于显示的价格，元单位
     */
	private String itemPromotionPrice;

	public Long getMemberId() {
		return memberId;
	}

	public void setMemberId(Long memberId) {
		this.memberId = memberId;
	}

	public String getMemberName() {
		return memberName;
	}

	public void setMemberName(String memberName) {
		this.memberName = memberName;
	}

	public Long getPublishMemberId() {
		return publishMemberId;
	}

	public void setPublishMemberId(Long publishMemberId) {
		this.publishMemberId = publishMemberId;
	}

	public String getPublishMemberName() {
		return publishMemberName;
	}

	public void setPublishMemberName(String publishMemberName) {
		this.publishMemberName = publishMemberName;
	}

	public String getTargetCode() {
		return targetCode;
	}

	public void setTargetCode(String targetCode) {
		this.targetCode = targetCode;
	}

	public Integer getType() {
		return type;
	}

	public void setType(Integer type) {
		this.type = type;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public Date getTimeAdd() {
		return timeAdd;
	}

	public void setTimeAdd(Date timeAdd) {
		this.timeAdd = timeAdd;
	}

	public Date getTimeEdit() {
		return timeEdit;
	}

	public void setTimeEdit(Date timeEdit) {
		this.timeEdit = timeEdit;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public Long getFavoritesId() {
		return favoritesId;
	}

	public void setFavoritesId(Long favoritesId) {
		this.favoritesId = favoritesId;
	}

	public String getItemName() {
		return itemName;
	}

	public void setItemName(String itemName) {
		this.itemName = itemName;
	}

	public String getItemPic() {
		return itemPic;
	}

	public void setItemPic(String itemPic) {
		this.itemPic = itemPic;
	}

	public String getItemPrice() {
		return itemPrice;
	}

	public void setItemPrice(String itemPrice) {
		this.itemPrice = itemPrice;
	}

	public String getItemPriceCurno() {
		return itemPriceCurno;
	}

	public void setItemPriceCurno(String itemPriceCurno) {
		this.itemPriceCurno = itemPriceCurno;
	}

	public String getItemPromotionPrice() {
		return String.valueOf(BigDecimalUtil.divide(new BigDecimal(itemPrice), new BigDecimal(100)));
	}

	public void setItemPromotionPrice(String itemPromotionPrice) {
		this.itemPrice = String.valueOf(BigDecimalUtil.multiply(itemPromotionPrice, "100").longValue());
	}

	public Integer getPublishFileId() {
		return publishFileId;
	}

	public void setPublishFileId(Integer publishFileId) {
		this.publishFileId = publishFileId;
	}

	public Integer getStock() {
		return stock;
	}

	public void setStock(Integer stock) {
		this.stock = stock;
	}

	public String getItemCode() {
		return itemCode;
	}

	public void setItemCode(String itemCode) {
		this.itemCode = itemCode;
	}

	public String getBrandTitle() {
		return brandTitle;
	}

	public void setBrandTitle(String brandTitle) {
		this.brandTitle = brandTitle;
	}

	public Integer getItemStatus() {
		return itemStatus;
	}

	public void setItemStatus(Integer itemStatus) {
		this.itemStatus = itemStatus;
	}

}